xl: use xrealloc in domain create
authorIan Campbell <ian.campbell@citrix.com>
Wed, 17 Feb 2016 14:04:14 +0000 (14:04 +0000)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Fri, 19 Feb 2016 16:02:51 +0000 (16:02 +0000)
commitb4aaf5a72f387c87e50a65224aa4c42ea4f768f6
tree0f154b4d45bd31fc089cbc97ccddecefcabe52db
parent435bbbc9af0f38d304e8be3a1ba00b99af530d60
xl: use xrealloc in domain create

Using bare realloc risks leaking the old pointer if the realloc fails.

Since xrealloc exits on such failures, drop the error handling.

Noticed while fixing, but not related to, CID 1055898.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
tools/libxl/xl_cmdimpl.c